{% extends "admin/change_form.html" %}
{% load tagging_tags %}

{% block extrahead %}
{{ block.super }}
<script type="text/javascript" src="{{ ZINNIA_MEDIA_URL }}js/jquery.js"></script>
<script type="text/javascript" src="{{ ZINNIA_MEDIA_URL }}js/jquery.bgiframe.js"></script>
<script type="text/javascript" src="{{ ZINNIA_MEDIA_URL }}js/jquery.autocomplete.js"></script>
<script type="text/javascript" src="{{ ZINNIA_MEDIA_URL }}js/wymeditor/jquery.wymeditor.pack.js"></script>
<script type="text/javascript">
$(document).ready(function() {
  {% tags_for_model zinnia.Entry as entry_tags %}
  var data = "{% for tag in entry_tags %}{{ tag.name }} {% endfor %}".split(" ");
  $("#id_tags").autocomplete(data, {
                width: 150, max: 10, highlight: false,
                multiple: true, multipleSeparator: ", ",
                scroll: true, scrollHeight: 300,
                matchContains: true, autoFill: true,});
  $("#id_content").wymeditor({
                   skin: "django", lang: "{{ LANGUAGE_CODE }}",
                   updateSelector: "input:submit", updateEvent: "click"});
});
</script>
{% endblock %}

{% block extrastyle %}
{{ block.super }}
<link type="text/css" rel="stylesheet" href="{{ ZINNIA_MEDIA_URL }}css/jquery.autocomplete.css" />
{% endblock %}

